<template>
  <el-dialog
    title=""
    :visible.sync="visible"
    width="80%"
    :before-close="handleClose"
  >
    <el-tabs type="border-card">
      <el-tab-pane label="基础信息">
        <el-form ref="ruleForm" :model="ruleForm" label-width="130px">
          <el-row type="flex" align="middle">
            <el-col :span="12">基础信息（JLP_TH202010-151008001）</el-col>
               <el-col :span="12" class="text-right">
                 <el-button type="success">入库完成</el-button>
               </el-col>
          </el-row>
          <el-divider content-position="center"></el-divider>
          <el-row>
            <el-col :span="6">
              <el-form-item label="门店:">
                <span>{{ ruleForm && ruleForm.storeName }}</span>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="新车订单号:">
                <span>{{ ruleForm && ruleForm.xcCode }}</span>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="退货仓库:">
                <span>{{ ruleForm && ruleForm.storageName }}</span>
              </el-form-item>
            </el-col>
          
            <el-col :span="6">
              <el-form-item label="品牌:">
                <span>{{ ruleForm && ruleForm.carBrandName }}</span>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="车系:">
                <span>{{ ruleForm && ruleForm.seriesName }}</span>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="车型:">
                <span>{{ ruleForm && ruleForm.modelName }}</span>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="供应商:">
                <span>{{ ruleForm && ruleForm.supplierName }}</span>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="进货来源:">
                <span class="data-money">￥{{ ruleForm.source }}111</span>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="库存状态:">
                <span>{{ ruleForm && ruleForm.status }}</span>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="购买日期:">
                <span>{{ ruleForm && ruleForm.gmrq }}</span>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="录入日期:">
                <span>{{ ruleForm && ruleForm.createTime }}</span>
              </el-form-item>
            </el-col>
            <el-col :span="24">
              <el-form-item label="退货原因:">
                <el-input placeholder="退货原因" disabled type="textarea" v-model="ruleForm.thDesc"/>
              </el-form-item>
            </el-col>
          </el-row>

          <el-row class="text-right">
             <el-col :span="6" >&nbsp;</el-col>
              <el-col :span="6" >
                <el-form-item label="退货客户:">
                  <span>{{ ruleForm && ruleForm.clientName }}/{{ruleForm && ruleForm.clientPhone}}</span>
                </el-form-item>
              </el-col>
              <el-col :span="6">
                <el-form-item label="销售人:">
                  <span>{{ ruleForm && ruleForm.sellUserName }}/{{ruleForm && ruleForm.sellUserPhone}}</span>
                </el-form-item>
              </el-col>
               <el-col :span="6" ></el-col>
          </el-row>
         
        </el-form>
      </el-tab-pane>
    </el-tabs>
  </el-dialog>
</template>

<script>
import DataTable from '@/components/DataTable'

export default {
  components: { DataTable },
  props: ['detailData', 'visible'],
  data() {
    return {
      innerVisible: false,
      tableData: [],
      pageSize: 10,
      currentPage: 1,
      totalCount: 0,
      amount: 0,
      putInNum: 0,
      tabPosition: '1',
      ruleForm: {},
      textarea: '',
      tableColumns: [
        { name: '品牌', value: 'partsCode', type: 'text' },
        { name: '车系', value: 'partsName', type: 'text' },
        { name: '年款', value: 'partsType', type: 'text' },
        { name: '车型', value: 'partsUnit', type: 'text' },
        { name: '级别', value: 'storageSiteName', type: 'text' },
        { name: '颜色', value: 'storageSiteCode', type: 'text' },
        { name: '数量', value: 'inStorageNum', type: 'text' },
        { name: '备注', value: 'all', type: 'text' },
        { name: '采购单价（万）', value: 'alreadyNum', type: 'text' },
        { name: '总金额（万）', value: 'num', type: 'text' },
      ],
    }
  },
  mounted() {
    if (this.detailData) {
      console.log(this.detailData.id)
    }
  },
  methods: {
    handleClose() {
      this.$emit('set-visible', false)
    },
    handleClick(val) {
      if (val === 2 || val === 3) {
        this.innerVisible = true
      }
    },
    handleSizeChange() {},
    handleCurrentChange() {},
  },
}
</script>

<style scoped>
</style>
